package service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Service;

import pojo.GroupMember;
import service.GroupmemberService;
import dao.GroupMemberDao;

@Service("gmsi")
public class GroupMemberServiceImpl implements GroupmemberService {
	@Autowired
	private GroupMemberDao dao;

	// 1
	public List<GroupMember> selectId(int groupId) {
		// TODO Auto-generated method stub
		return dao.selectId(groupId);
	}

	// 2
	public int insertUserToGroup(GroupMember gmember) {
		// TODO Auto-generated method stub
		return dao.insertUserToGroup(gmember);
	}

	// 3
	public int updateUser(GroupMember gmember) {
		// TODO Auto-generated method stub
		return dao.updateUser(gmember);
	}

	// 4
	public int updatePictrue(GroupMember gmember) {
		// TODO Auto-generated method stub
		return dao.updatePictrue(gmember);
	}

	// 5
	public int updateAnswer(GroupMember gmember) {
		// TODO Auto-generated method stub
		return dao.updateAnswer(gmember);
	}

	// 6
	public int updateScore(GroupMember gmember) {
		// TODO Auto-generated method stub
		return dao.updateScore(gmember);
	}

	
	// 7
	public int delectUser(int groupMemberUserid) {
		// TODO Auto-generated method stub
		return dao.delectUser(groupMemberUserid);
	}

	public GroupMemberDao getDao() {
		return dao;
	}

	public void setDao(GroupMemberDao dao) {
		this.dao = dao;
	}
}
